<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>进度条作业</title>
    <style>
      * {
        margin: 0;
        padding: 0;
        list-style: none;
        text-decoration: none;
      }

      div {
        margin-bottom: 20px;
      }

      .progress-1 {
        width: 120px;
        height: 20px;
        background: #ddd linear-gradient(#000 0 0) 0/0% no-repeat;
        animation: p1 2s infinite linear;
      }
      @keyframes p1 {
        100% {
          background-size: 100%;
        }
      }
      .progress-2 {
        width: 120px;
        height: 20px;
        border-radius: 5px;
        background: #ddd linear-gradient(to right, #e6657b, skyblue) 0/0%
          no-repeat;
        animation: p2 2s infinite linear;
      }
      @keyframes p2 {
        100% {
          background-size: 100%;
        }
      }
      .progress-3 {
        width: 120px;
        height: 20px;
        border-radius: 10px;
        /* background: repeating-linear-gradient(135deg,#f03355 0 10px,orange 0 20px) 0/0% no-repeat,repeating-linear-gradient(135deg,#ddd 0 10px,#eee 0 20px) 0/100%; */
        background: repeating-linear-gradient(
              135deg,
              #d9164a 0 10px,
              #f7961d 0 20px
            )
            no-repeat 0 0/0%,
          repeating-linear-gradient(135deg, white 0px 10px, #ddd 0 20px)
            no-repeat 0px 0px/100%;

        animation: p3 2s infinite;
      }
      @keyframes p3 {
        100% {
          background-size: 100%;
        }
      }
      .progress-4 {
        width: 120px;
        height: 20px;
        background: repeating-linear-gradient(
              to right,
              #000 0 20px,
              #fff 0 25px
            )
            0/0% no-repeat,
          repeating-linear-gradient(to right, #dbdbdb 0 20px, #fff 0 25px) 0/100%;
        animation: p5 3s steps(6) infinite;
      }
      @keyframes p5 {
        100% {
          background-size: 120%;
        }
      }
    </style>
  </head>
  <body>
    <div class="progress-1"></div>
    <div class="progress-2"></div>
    <div class="progress-3"></div>
    <div class="progress-4"></div>
  </body>
</html>
